package RJ;

import java.util.*;

public class RoomTable {
	
	private HashMap<String,Room> RT;
	Iterator iter = null;
	
	public Iterator getIter() {		
		return iter = getRT().values().iterator();
	}

	public RoomTable(){
		setRT(new HashMap<String,Room>());
	}
	public void insert(String room) {
		getRT().put(room, new Room(room));		
	}
	public boolean selectName(String r) {
		return getRT().containsKey(r);
	}
	public Room getRoom(String room) {
		return getRT().get(room);
	}
	@Override
	public String toString(){
		return getRT().toString();		
	}

	public HashMap<String,Room> getRT() {
		return RT;
	}

	public void setRT(HashMap<String,Room> rT) {
		RT = rT;
	}
	
	public int getSize(){
		return RT.size();
	}

}
